class ServiceInformationTablesController < ApplicationController
  def index
    @service_information_tables = ServiceInformationTable.all
    respond_to do |format|
      format.html
      format.csv  { send_data ServiceInformationTable.to_csv }
      format.xls
    end
  end

  def show
    @service_information_table = ServiceInformationTable.find(params[:id])
  end

  def new
    @service_information_table = ServiceInformationTable.new
  end

  def create
    @service_information_table = ServiceInformationTable.new(params[:service_information_table])
    if @service_information_table.save
      redirect_to @service_information_table, :notice => "Successfully created service information table."
    else
      render :action => 'new'
    end
  end

  def edit
    @service_information_table = ServiceInformationTable.find(params[:id])
  end

  def update
    @service_information_table = ServiceInformationTable.find(params[:id])
    if @service_information_table.update_attributes(params[:service_information_table])
      redirect_to @service_information_table, :notice  => "Successfully updated service information table."
    else
      render :action => 'edit'
    end
  end

  def destroy
    @service_information_table = ServiceInformationTable.find(params[:id])
    @service_information_table.destroy
    redirect_to service_information_tables_url, :notice => "Successfully destroyed service information table."
  end
end
